<?php

$alternateContent = file_get_contents('alternate_content.txt');

define('PAGE_TITLE', 'JSUG Voting');

# makes firefox not displaying the flashcontent anymore :(
# <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
# <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
?>
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en">
<head>

	<title><?= PAGE_TITLE ?></title>
	
	<meta http-equiv="Content-Type"     content="text/html; charset=utf-8" />
	<meta http-equiv="content-language" content="en">
	<meta name="description"            content="Voting tool for the Java Student User Group">
	<meta name="keywords"               content="Java, Flex, Usergroup, Vote">
	<meta name="author"                 content="Christoph Pickl">
	<meta name="publisher"              content="JavaStudentUserGroup">
	<meta name="copyright"              content="JavaStudentUserGroup">
	<meta name="robots"                 content="INDEX,FOLLOW">
	
	<script src="js/swfaddress.js"              type="text/javascript"></script>	
	<script src="js/swfobject.js"               type="text/javascript"></script>
	<script src="js/swfmacmousewheel2.js"       type="text/javascript"></script>
	<script src="history/history.js"            type="text/javascript"></script>
	
	<link  href="history/history.css" rel="stylesheet" type="text/css"        />
	
	<script type="text/javascript">
	
		var swfUri = "${swf}.swf";
		var htmlTagIdForFlash = "flashcontainer"; 
		var flashPlayerVersion = "${version_major}.${version_minor}.${version_revision}";
		var flashvars = { };
		flashvars.pageTitle = '<?= PAGE_TITLE ?>';
		
		var params = { }; // params within object element params
		params.allowScriptAccess = "always"; // "sameDomain"
		params.allowfullscreen = true;
		
		var attributes = {}; // object's attributes
		attributes.id = "jsugVotingSwf"; 
		
		swfobject.embedSWF(swfUri, htmlTagIdForFlash, "${width}", "${height}", flashPlayerVersion, "expressInstall.swf", flashvars, params, attributes);
		  
		swfmacmousewheel.registerObject(attributes.id);
	</script>
	
	<style type="text/css" media="screen">
		body { margin:0; padding:0; overflow:hidden; }
	</style>
	<link href="noflash.css" rel="stylesheet" type="text/css" media="screen" />

</head>
<body>

	<div id="flashcontainer">
	
		<?php echo $alternateContent; ?>
	
	</div>

</body>
</html>